Fog computing is a complementary solution to the traditional cloud-computing approach. Fog nodes are machines running directly on an edge network that have storage and compute power and can run applications, implement caches, or preprocess data. However, as the nodes have to be deployed on the edge, fog computing (in “the Fog”) is not as elastic as current cloud platforms (“the Cloud”). For instance, applications may be running on a fog platform, with a fixed compute and memory capacity, where the fog node acts as both a cache and a compute platform. In case of a sudden burst of requests to the applications (e.g., a flash crowd), storage and compute space can be rented in the Cloud to offload some of the processing. In such a situation, however, current systems are generally inefficient in determining which requests should be computed in the Fog, and which should be forwarded to the Cloud.